package com.xinqi.modules.user.auth.form;

import com.xinqi.common.core.constant.UserConstants;
import lombok.Data;
import lombok.NoArgsConstructor;
import org.hibernate.validator.constraints.Length;

import javax.validation.constraints.NotBlank;

/**
 * 用户登录对象
 *
 * @author dgyu
 */
@Data
@NoArgsConstructor
public class LoginBody {

    /**
     * 用户名
     */
    @NotBlank(message = "{user.username.not.blank}")
    @Length(min = UserConstants.USERNAME_MIN_LENGTH, max = UserConstants.USERNAME_MAX_LENGTH, message = "{user.username.length.valid}")
    private String username;

    /**
     * 用户密码
     */
    @NotBlank(message = "{user.password.not.blank}")
    private String password;

    /**
     * 设备类型 pc Android ios
     */
    @NotBlank(message = "设备类型不能为空 pc Android ios")
    private String deviceType;

    /**
     * imei,默认传0
     */
    private String imei;

    /**
     * 手机名称
     */
    private String phonetitle;

    /**
     * 苹果手机id
     */
    private String appleUid;
    /**
     * 图形验证码
     */
    //@NotBlank(message = "{captcha.code.not.blank}")
    //private String  captchaVerification;

}
